import { Injectable } from '@angular/core';
import { HttpClient, HttpParams } from '@angular/common/http';

@Injectable({
  providedIn: 'root'
})
export class AdminService {

  constructor(private http: HttpClient) { }


  search(keyword) {
    const params: HttpParams = new HttpParams().append('keyword', keyword);
    return this.http.get('/api/search', { params })
  }
}
